package com.xyg.pojo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;
import org.springframework.data.mongodb.core.mapping.Field;

@Data
@AllArgsConstructor
@NoArgsConstructor
@Document( collection = "reviews" )
public class Review {

    @Id
    private String id;
    @Field( "product_id" )
    private String productId; // 关联的商品ID
    @Field( "user_id" )
    private String userId;    // 关联的用户ID
    @Field( "comment" )
    private String comment;   // 评论内容
}